package com.example.myapplication.old;

import androidx.appcompat.app.AppCompatActivity;
import androidx.viewpager.widget.ViewPager;

import android.content.Context;
import android.os.Bundle;

import com.example.myapplication.R;
import com.example.myapplication.old.adapter.ViewPageAdapter;
import com.google.android.material.tabs.TabLayout;

public class RankingActivity extends AppCompatActivity {
    private ViewPager viewpage;
    private TabLayout tabLayout;
    private Context context;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        context=this;
        setContentView(R.layout.activity_view_page_main);
        viewpage=findViewById(R.id.recyclerView1);
        tabLayout=findViewById(R.id.tab_layout);
        ViewPageAdapter adapter = new ViewPageAdapter(getSupportFragmentManager());
        viewpage.setAdapter(adapter);

        tabLayout.setupWithViewPager(viewpage);


    }
}